import static org.junit.Assert.*;

import org.junit.Test;

//import sun.security.mscapi.KeyStore.MY;

import com.sun.org.apache.xml.internal.security.utils.HelperNodeList;


public class MainTest {
	
	@Test
	public void testHello() {
		assertEquals("The result should be 'Hello World!'","Hello World!", Main.hello());
	}
	
	@Test
	public void testHail() {
		String name = "ali";
		assertEquals("Hello, ali!\nMerhaba, ali!\nSalut, ali!\nSaluton, ali!\n","Hello, "+name+"!\nMerhaba, "+name+"!\nSalut, "+name+"!\nSaluton, "+name+"!\n", Main.hail(name));
		String name2 = "veli";
		assertEquals("Hello, veli!\nMerhaba, veli!\nSalut, veli!\nSaluton, veli!\n","Hello, "+name2+"!\nMerhaba, "+name2+"!\nSalut, "+name2+"!\nSaluton, "+name2+"!\n", Main.hail(name2));
	}
	
	@Test
	public void testGood_day(){
		assertEquals("The result should be 'Good morning!'","Good morning!", Main.good_day(4));
		assertEquals("The result should be 'Good afternoon!'","Good afternoon!", Main.good_day(13));
		assertEquals("The result should be 'Good evening!'","Good evening!", Main.good_day(20));
		assertEquals("The result should be 'Good night!'","Good night!", Main.good_day(2));
	}
	
	@Test
	public void testPower(){
		assertEquals("The result should be 16",4*4, Main.power(4));
		assertEquals("The result should be 625",25*25, Main.power(25));
	}
	
	@Test
	public void testPrintGrade(){
		assertEquals("The result should be A","A", Main.printGrade(96.0));
		assertEquals("The result should be B","B", Main.printGrade(85.0));
	}
	
	@Test
	public void testFibo_Burak(){
		assertEquals("The result should be 1",0, Main.fibo_Burak(1));
		assertEquals("The result should be 1",1, Main.fibo_Burak(2));
		assertEquals("The result should be 2",2, Main.fibo_Burak(3));
	}
	
	@Test
	public void testFindMax(){
		assertEquals("The result should be 2",2, Main.findMax(1,2));
		assertEquals("The result should be 102",102, Main.findMax(89,102));
		assertEquals("The result should be 68795",68795, Main.findMax(5698,68795));
	}
	
}


